package com.ctshk.rpc.user.entity.es;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.experimental.Accessors;
import org.springframework.data.elasticsearch.annotations.DateFormat;
import org.springframework.data.elasticsearch.annotations.Field;
import org.springframework.data.elasticsearch.annotations.FieldType;

import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * <p>
 *  机票订单行程信息数组
 * </p>
 *
 * @author 李新科
 * @date 2021/5/27 20:53
 */
@Data
@ApiModel(value="机票订单行程信息ES缓存实体")
@Accessors(chain = true)
public class AirOrderTripEs implements Serializable {

    @ApiModelProperty(value = "航空公司名称")
    private String companyName;

    @ApiModelProperty(value = "第几程")
    private Integer tripRank;

    @ApiModelProperty(value = "航班号")
    private String flightNumber;

    @ApiModelProperty(value = "出发日期时间")
    @Field(type = FieldType.Date, format = DateFormat.custom, pattern = "uuuu-MM-dd HH:mm:ss")
    private LocalDateTime depDateTime;

    @ApiModelProperty(value = "出发地名称")
    private String depCityName;

    @ApiModelProperty(value = "到达地名称")
    private String arrCityName;

    @ApiModelProperty(value = "起飞机场")
    private String depAirportName;

    @ApiModelProperty(value = "到达机场")
    private String arrAirportName;

    @ApiModelProperty(value = "到达日期时间")
    @Field(type = FieldType.Date, format = DateFormat.custom, pattern = "uuuu-MM-dd HH:mm:ss")
    private LocalDateTime arrDateTime;

    @ApiModelProperty(value = "耗时")
    private String timeConsuming;
}
